#include <Avance.incl>
#include <Delay.incl>
#include <Grad.incl>

"d0=3u"
"d11=30m"
"d12=20u"
"d13=4u"

"FACTOR1=(d9/(p6*115.112))/2+0.5"
"l1=FACTOR1*2"
"d15=l1*p6*115.112"
"d16=d15+5u+50u+300u+p11+100u+5u+5u+300u+p12+d6+100u+5u+d7"
"d17=d16"
"in0=inf1"

"acqt0=-p1*2/3.1416"

1 ze 
2 d11
3 d12 pl9:f2
  d12 BLKGRAD
  d1 cw:f2 ph29
  d13 do:f2
  d12 pl1:f1

  p1 ph1
  d0
  p1 ph2
  5u pl0:f1
  50u UNBLKGRAD
  300u gron0
  p11:sp1:f1 ph4
  100u groff
  5u pl10:f1

4 p6*3.556 ph23
  p6*4.556 ph25
  p6*3.222 ph23
  p6*3.167 ph25
  p6*0.333 ph23
  p6*2.722 ph25
  p6*4.167 ph23
  p6*2.944 ph25
  p6*4.111 ph23
  
  p6*3.556 ph25
  p6*4.556 ph23
  p6*3.222 ph25
  p6*3.167 ph23
  p6*0.333 ph25
  p6*2.722 ph23
  p6*4.167 ph25
  p6*2.944 ph23
  p6*4.111 ph25

  p6*3.556 ph25
  p6*4.556 ph23
  p6*3.222 ph25
  p6*3.167 ph23
  p6*0.333 ph25
  p6*2.722 ph23
  p6*4.167 ph25
  p6*2.944 ph23
  p6*4.111 ph25

  p6*3.556 ph23
  p6*4.556 ph25
  p6*3.222 ph23
  p6*3.167 ph25
  p6*0.333 ph23
  p6*2.722 ph25
  p6*4.167 ph23
  p6*2.944 ph25
  p6*4.111 ph23
  lo to 4 times l1

  5u pl0:f1
  d6 gron5
  300u gron0
  p12:sp2:f1 ph4
  100u groff
  d7
  5u pl1:f1

  p1 ph3

  go=2 ph31

  

  d11 mc #0 to 2 F1PH(calph(ph1, +90), caldel(d0, +in0))
  d17 ; to display d17 correct value in ased
exit 
   

ph1=0 2
ph2=0 0
ph3=0 0
ph4=0
ph5=0
ph23=3
ph25=1
ph29=0
ph31=0 2


;pl0 : zero power (120 dB)
;pl1 : f1 channel - power level for pulse
;pl9 : f2 channel - power level for presaturation
;pl10: DIPSI-2 power
;p1  : 90 degree high power pulse
;p6  : 90 degree low power pulse
;p11 : duration of first sweep
;p12 : duration of second sweep
;d0  : incremented delay
;d1  : relaxation delay
;d6  : duration of homospoil
;d7  : recovery delay
;d9  : TOCSY mixing time
;d15 : actual TOCSY mixing time
;d16 : time between 2nd and 3rd 90's
;d17 : id. d16
;sp1 : strength for first sweep
;sp2 : strength for second sweep
;gpz0: gradient strength for ZQ suppression
;gpz5: gradient strength for homospoil
;l1  : loop for DIPSI cycle
;nd0 : 2
;NS  : 2 * n
;DS  : 8
;td1 : number of t1 increments
;MC2 : TPPI












